package com.younion.common.constants;


public enum RoleType {
	
	SUPPER("SUPPER","超级管理员"), COMMON("COMMON","一般管理员"), CUSTOMER("CUSTOMER","商家管理员"), SHOP("SHOP","分店管理员");
	private String name;
	private String title;

	private RoleType(String name,String title) {
		this.name = name;
		this.title = title;
	}

	public String getName() {
		return name;
	}
	
	public String getTitle(){
		return title;
	}

	public static RoleType valueOfName(String name) {
		for (RoleType e : RoleType.values()) {
			if (e.getName().equals(name)) {
				return e;
			}
		}
		return null;
	}

	public static void main(String[] args) {
		System.out.print(RoleType.valueOfName("*"));
	}
	
}
